<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改施工过程')" />
    <th:block th:include="include :: datetimepicker-css" />
    <th:block th:include="include :: jasny-bootstrap-css" />
    <th:block th:include="include :: bootstrap-fileinput-css" />
	<style>
		.file-preview {
		    padding: 0;
		    margin-bottom: 0;
		    border-radius: 0;
		    border: none;
		}
		
		.krajee-default.file-preview-frame {
		    margin-right: 20px;
		    padding: 0;
		    border: none;
		    box-shadow: none;
		}
		
		.krajee-default.file-preview-frame:not(.file-preview-error):hover {
		    border: none;
		    box-shadow: none;
		}
		
		.krajee-default .file-footer-caption {
			margin-bottom: 0;
		}
		
		.krajee-default.file-preview-frame .file-thumbnail-footer {
		    height: auto;
		}
		
		.krajee-default .file-caption-info {
			width: auto;
		}
		
		.kv-upload-progress .progress {
			margin-top: 0;
		}
		
		.krajee-default.file-preview-frame .kv-file-content,
		.krajee-default .file-size-info,
		.krajee-default .file-upload-indicator,
		.file-input .kv-file-upload,
		.file-input .kv-file-zoom {
			display: none;
		}
		
		.file-input .kv-file-remove {
			position: absolute;
			top: 3px;
			right: -15px;
			height: 14px;
			padding: 0;
			margin: 0;
			border: none;
			background: none;
		}
		
		.file-input .kv-file-remove:active, 
		.file-input .kv-file-remove:focus {
			background: none;
			outline: none;
			box-shadow: none;
		}
		
		.file-input .kv-file-remove .glyphicon-trash {
			color: red;
		}
	</style>
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-sgazhtgc-edit" th:object="${gcProjectSgazhtgc}" enctype="multipart/form-data" method="post">
            <input name="id" th:field="*{id}" type="hidden">
            <input name="gcProjectid" th:field="*{gcProjectid}" type="hidden">
            <input name="sgazhtId" th:field="*{sgazhtId}" type="hidden">
            <input type="hidden" id="zilwj" name="zilwj" th:value="*{zilwj}" />
            <input type="hidden" id="zilwjvo" name="zilwjvo" th:value="${zilwjvo}" />
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">项目编号：</label>
                <div class="col-sm-8">
                    <input name="orderNo" th:field="*{orderNo}" class="form-control" type="text" autoComplete="off" readonly="readonly" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">项目名称：</label>
                <div class="col-sm-8">
                    <input name="name" class="form-control" type="text" autoComplete="off" th:value="${gcProject.name}" readonly="readonly" required/>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">施工单位名称：</label>
                <div class="col-sm-8">
                    <input name="name" class="form-control" type="text" autoComplete="off" th:value="${gcProjectSgazht.supplyName}" readonly="readonly" required/>
                </div>
            </div>
<!--             <div class="form-group">  -->
<!--             	<label class="col-sm-3 control-label is-required">施工类型：</label> -->
<!--                 <div class="col-sm-8"> -->
<!--                     <select name="type" th:field="*{type}" class="form-control" required th:with="type=${@dict.getType('gcgl_sggc_type')}"> -->
<!-- 		                <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictLabel}"></option> -->
<!-- 		            </select> -->
<!--                 </div> -->
<!--             </div> -->
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">施工开始时间：</label>
                <div class="col-sm-8">
                    <div class="input-group date">
                        <input name="riq" th:value="${#dates.format(gcProjectSgazhtgc.riq, 'yyyy-MM-dd')}" required class="form-control" placeholder="yyyy-MM-dd" type="text" autoComplete="off">
                        <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                    </div>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">施工结束时间：</label>
                <div class="col-sm-8">
                    <div class="input-group date">
                        <input name="endAt" th:value="${#dates.format(gcProjectSgazhtgc.endAt, 'yyyy-MM-dd')}" required class="form-control" placeholder="yyyy-MM-dd" type="text" autoComplete="off">
                        <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                    </div>
                </div>
            </div>
<!--             <div class="form-group"> -->
<!--                 <label class="col-sm-3 control-label is-required">施工过程：</label> -->
<!--                 <div class="col-sm-8"> -->
<!--                     <textarea name="descs" class="form-control" required>[[*{descs}]]</textarea> -->
<!--                 </div> -->
<!--             </div> -->
            <div class="form-group">
                <label class="col-sm-3 control-label">施工过程图片：</label>
                <div class="col-sm-8" style="margin-top: 8px;" id="zlwjlink">
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <th:block th:include="include :: datetimepicker-js" />
    <th:block th:include="include :: jasny-bootstrap-js" />
    <script th:src="@{/ruoyi/base64.min.js?v=20231208}"></script>
    <th:block th:include="include :: bootstrap-fileinput-js" />
    <th:block th:include="include :: bootstrap-suggest-js" />
    <th:block th:include="include :: bootstrap-typeahead-js" />
    <script th:inline="javascript">
        var prefix = ctx + "gcgl/sgazhtgc";
        $("#form-sgazhtgc-edit").validate({
            focusCleanup: true
        });
        
        $(function() {
			var zilwj = $("#zilwjvo").val();
        	var n=zilwj.split(",");
        	for(var i=0;i<n.length;i++){
        		if(n[i]!=""){
// 	        		var url = "http://lkgnews.cn:8012/onlinePreview?url="+encodeURIComponent(Base64.encode(n[i]));
	        		var url = n[i];
        		$("#zlwjlink").append("<a href='"+url+"' target='_blank' >"+n[i]+"</a>&nbsp;&nbsp;&nbsp;&nbsp;");
	        		$("#zlwjlink").append("<a href='"+n[i]+"' target='_blank' >下载</a><br>");
        		}
        	}
        	
        });

        $("input[name='riq']").datetimepicker({
            format: "yyyy-mm-dd",
            minView: "month",
            autoclose: true
        });
        
        $("input[name='endAt']").datetimepicker({
            format: "yyyy-mm-dd",
            minView: "month",
            autoclose: true
        });

    </script>
</body>
</html>